package com.imooc.order.message;

import lombok.extern.slf4j.Slf4j;
import org.springframework.cloud.stream.annotation.EnableBinding;
import org.springframework.cloud.stream.annotation.StreamListener;
import org.springframework.stereotype.Component;

/**
 * @Name com.imooc.order.message.StreamReceiver
 * @Description
 * @Author Elwyn
 * @Version 2020/3/19
 * @Copyright 上海云辰信息科技有限公司
 **/
@Component
@EnableBinding(StreamClient.class)
@Slf4j
public class StreamReceiver {

	@StreamListener("myMessage")
	public void process(Object message) {
		log.info("StreamReceiver: {}", message);
	}
}
